3.376 \(\int \frac{\sqrt{\cos (c+d x)}}{a+a \sec (c+d x)} \, dx\)

Optimal. Leaf size=72 \[ -\frac{\text{EllipticF}\left (\frac{1}{2} (c+d x),2\right )}{a d}+\frac{3 E\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{a d}-\frac{\sin (c+d x)}{d \sqrt{\cos (c+d x)} (a \sec (c+d x)+a)} \]

[Out]

(3*EllipticE[(c + d*x)/2, 2])/(a*d) - EllipticF[(c + d*x)/2, 2]/(a*d) - Sin[c + d*x]/(d*Sqrt[Cos[c + d*x]]*(a
+ a*Sec[c + d*x]))

________________________________________________________________________________________

Rubi [A]  time = 0.147076, antiderivative size = 72, normalized size of antiderivative = 1., number of steps used = 7, number of rules used = 6, integrand size = 23, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.261, Rules used = {4264, 3819, 3787, 3771, 2639, 2641} \[ -\frac{F\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{a d}+\frac{3 E\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{a d}-\frac{\sin (c+d x)}{d \sqrt{\cos (c+d x)} (a \sec (c+d x)+a)} \]

Antiderivative was successfully verified.

[In]

Int[Sqrt[Cos[c + d*x]]/(a + a*Sec[c + d*x]),x]

[Out]

(3*EllipticE[(c + d*x)/2, 2])/(a*d) - EllipticF[(c + d*x)/2, 2]/(a*d) - Sin[c + d*x]/(d*Sqrt[Cos[c + d*x]]*(a
+ a*Sec[c + d*x]))

Rule 4264

Int[(u_)*((c_.)*sin[(a_.) + (b_.)*(x_)])^(m_.), x_Symbol] :> Dist[(c*Csc[a + b*x])^m*(c*Sin[a + b*x])^m, Int[A
ctivateTrig[u]/(c*Csc[a + b*x])^m, x], x] /; FreeQ[{a, b, c, m}, x] &&  !IntegerQ[m] && KnownSecantIntegrandQ[
u, x]

Rule 3819

Int[(csc[(e_.) + (f_.)*(x_)]*(d_.))^(n_)/(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)), x_Symbol] :> Simp[(Cot[e + f*
x]*(d*Csc[e + f*x])^n)/(f*(a + b*Csc[e + f*x])), x] - Dist[1/a^2, Int[(d*Csc[e + f*x])^n*(a*(n - 1) - b*n*Csc[
e + f*x]), x], x] /; FreeQ[{a, b, d, e, f}, x] && EqQ[a^2 - b^2, 0] && LtQ[n, 0]

Rule 3787

Int[(csc[(e_.) + (f_.)*(x_)]*(d_.))^(n_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_)), x_Symbol] :> Dist[a, Int[(d*
Csc[e + f*x])^n, x], x] + Dist[b/d, Int[(d*Csc[e + f*x])^(n + 1), x], x] /; FreeQ[{a, b, d, e, f, n}, x]

Rule 3771

Int[(csc[(c_.) + (d_.)*(x_)]*(b_.))^(n_), x_Symbol] :> Dist[(b*Csc[c + d*x])^n*Sin[c + d*x]^n, Int[1/Sin[c + d
*x]^n, x], x] /; FreeQ[{b, c, d}, x] && EqQ[n^2, 1/4]

Rule 2639

Int[Sqrt[sin[(c_.) + (d_.)*(x_)]], x_Symbol] :> Simp[(2*EllipticE[(1*(c - Pi/2 + d*x))/2, 2])/d, x] /; FreeQ[{
c, d}, x]

Rule 2641

Int[1/Sqrt[sin[(c_.) + (d_.)*(x_)]], x_Symbol] :> Simp[(2*EllipticF[(1*(c - Pi/2 + d*x))/2, 2])/d, x] /; FreeQ
[{c, d}, x]

Rubi steps

\begin{align*} \int \frac{\sqrt{\cos (c+d x)}}{a+a \sec (c+d x)} \, dx &=\left (\sqrt{\cos (c+d x)} \sqrt{\sec (c+d x)}\right ) \int \frac{1}{\sqrt{\sec (c+d x)} (a+a \sec (c+d x))} \, dx\\ &=-\frac{\sin (c+d x)}{d \sqrt{\cos (c+d x)} (a+a \sec (c+d x))}-\frac{\left (\sqrt{\cos (c+d x)} \sqrt{\sec (c+d x)}\right ) \int \frac{-\frac{3 a}{2}+\frac{1}{2} a \sec (c+d x)}{\sqrt{\sec (c+d x)}} \, dx}{a^2}\\ &=-\frac{\sin (c+d x)}{d \sqrt{\cos (c+d x)} (a+a \sec (c+d x))}-\frac{\left (\sqrt{\cos (c+d x)} \sqrt{\sec (c+d x)}\right ) \int \sqrt{\sec (c+d x)} \, dx}{2 a}+\frac{\left (3 \sqrt{\cos (c+d x)} \sqrt{\sec (c+d x)}\right ) \int \frac{1}{\sqrt{\sec (c+d x)}} \, dx}{2 a}\\ &=-\frac{\sin (c+d x)}{d \sqrt{\cos (c+d x)} (a+a \sec (c+d x))}-\frac{\int \frac{1}{\sqrt{\cos (c+d x)}} \, dx}{2 a}+\frac{3 \int \sqrt{\cos (c+d x)} \, dx}{2 a}\\ &=\frac{3 E\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{a d}-\frac{F\left (\left .\frac{1}{2} (c+d x)\right |2\right )}{a d}-\frac{\sin (c+d x)}{d \sqrt{\cos (c+d x)} (a+a \sec (c+d x))}\\ \end{align*}

Mathematica [C]  time = 2.08641, size = 270, normalized size = 3.75 \[ \frac{\cos ^2\left (\frac{1}{2} (c+d x)\right ) \left (-\frac{2 \left (\sec \left (\frac{c}{2}\right ) \sin \left (\frac{d x}{2}\right ) \sec \left (\frac{1}{2} (c+d x)\right )+2 \cot (c)+\csc (c)\right )}{d \sqrt{\cos (c+d x)}}+\frac{2 i \sqrt{2} e^{-i (c+d x)} \sec (c+d x) \left (3 \left (-1+e^{2 i c}\right ) \sqrt{1+e^{2 i (c+d x)}} \text{Hypergeometric2F1}\left (-\frac{1}{4},\frac{1}{2},\frac{3}{4},-e^{2 i (c+d x)}\right )+\left (-1+e^{2 i c}\right ) e^{i (c+d x)} \sqrt{1+e^{2 i (c+d x)}} \text{Hypergeometric2F1}\left (\frac{1}{4},\frac{1}{2},\frac{5}{4},-e^{2 i (c+d x)}\right )+3 \left (1+e^{2 i (c+d x)}\right )\right )}{\left (-1+e^{2 i c}\right ) d \sqrt{e^{-i (c+d x)} \left (1+e^{2 i (c+d x)}\right )}}\right )}{a (\sec (c+d x)+1)} \]

Antiderivative was successfully verified.

[In]

Integrate[Sqrt[Cos[c + d*x]]/(a + a*Sec[c + d*x]),x]

[Out]

(Cos[(c + d*x)/2]^2*(((2*I)*Sqrt[2]*(3*(1 + E^((2*I)*(c + d*x))) + 3*(-1 + E^((2*I)*c))*Sqrt[1 + E^((2*I)*(c +
 d*x))]*Hypergeometric2F1[-1/4, 1/2, 3/4, -E^((2*I)*(c + d*x))] + E^(I*(c + d*x))*(-1 + E^((2*I)*c))*Sqrt[1 +
E^((2*I)*(c + d*x))]*Hypergeometric2F1[1/4, 1/2, 5/4, -E^((2*I)*(c + d*x))])*Sec[c + d*x])/(d*E^(I*(c + d*x))*
(-1 + E^((2*I)*c))*Sqrt[(1 + E^((2*I)*(c + d*x)))/E^(I*(c + d*x))]) - (2*(2*Cot[c] + Csc[c] + Sec[c/2]*Sec[(c
+ d*x)/2]*Sin[(d*x)/2]))/(d*Sqrt[Cos[c + d*x]])))/(a*(1 + Sec[c + d*x]))

________________________________________________________________________________________

Maple [A]  time = 1.555, size = 199, normalized size = 2.8 \begin{align*}{\frac{1}{da}\sqrt{ \left ( 2\, \left ( \cos \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}-1 \right ) \left ( \sin \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) \right ) ^{2}} \left ( \cos \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) \sqrt{ \left ( \sin \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) \right ) ^{2}}\sqrt{2\, \left ( \sin \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}-1} \left ({\it EllipticF} \left ( \cos \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) ,\sqrt{2} \right ) +3\,{\it EllipticE} \left ( \cos \left ( 1/2\,dx+c/2 \right ) ,\sqrt{2} \right ) \right ) +2\, \left ( \sin \left ( 1/2\,dx+c/2 \right ) \right ) ^{4}- \left ( \sin \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) \right ) ^{2} \right ){\frac{1}{\sqrt{-2\, \left ( \sin \left ( 1/2\,dx+c/2 \right ) \right ) ^{4}+ \left ( \sin \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) \right ) ^{2}}}} \left ( \cos \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) \right ) ^{-1} \left ( \sin \left ({\frac{dx}{2}}+{\frac{c}{2}} \right ) \right ) ^{-1}{\frac{1}{\sqrt{2\, \left ( \cos \left ( 1/2\,dx+c/2 \right ) \right ) ^{2}-1}}}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(d*x+c)^(1/2)/(a+a*sec(d*x+c)),x)

[Out]

((2*cos(1/2*d*x+1/2*c)^2-1)*sin(1/2*d*x+1/2*c)^2)^(1/2)*(cos(1/2*d*x+1/2*c)*(sin(1/2*d*x+1/2*c)^2)^(1/2)*(2*si
n(1/2*d*x+1/2*c)^2-1)^(1/2)*(EllipticF(cos(1/2*d*x+1/2*c),2^(1/2))+3*EllipticE(cos(1/2*d*x+1/2*c),2^(1/2)))+2*
sin(1/2*d*x+1/2*c)^4-sin(1/2*d*x+1/2*c)^2)/a/(-2*sin(1/2*d*x+1/2*c)^4+sin(1/2*d*x+1/2*c)^2)^(1/2)/cos(1/2*d*x+
1/2*c)/sin(1/2*d*x+1/2*c)/(2*cos(1/2*d*x+1/2*c)^2-1)^(1/2)/d

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\sqrt{\cos \left (d x + c\right )}}{a \sec \left (d x + c\right ) + a}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^(1/2)/(a+a*sec(d*x+c)),x, algorithm="maxima")

[Out]

integrate(sqrt(cos(d*x + c))/(a*sec(d*x + c) + a), x)

________________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left (\frac{\sqrt{\cos \left (d x + c\right )}}{a \sec \left (d x + c\right ) + a}, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^(1/2)/(a+a*sec(d*x+c)),x, algorithm="fricas")

[Out]

integral(sqrt(cos(d*x + c))/(a*sec(d*x + c) + a), x)

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \frac{\int \frac{\sqrt{\cos{\left (c + d x \right )}}}{\sec{\left (c + d x \right )} + 1}\, dx}{a} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)**(1/2)/(a+a*sec(d*x+c)),x)

[Out]

Integral(sqrt(cos(c + d*x))/(sec(c + d*x) + 1), x)/a

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\sqrt{\cos \left (d x + c\right )}}{a \sec \left (d x + c\right ) + a}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^(1/2)/(a+a*sec(d*x+c)),x, algorithm="giac")

[Out]

integrate(sqrt(cos(d*x + c))/(a*sec(d*x + c) + a), x)